#include "ViewportLink.h"

namespace k2graphics
{

ViewportLink::ViewportLink(int vplID)
{
	linkID = vplID;
	src = NULL;
	dest = NULL;
	srcID = -1;
	destID = -1;
}

void ViewportLink::updateLink(double dt)
{
	if(src != NULL)
		src->writeSettings();
}

void ViewportLink::setLocalSrc(AbstractViewport* nsrc, int nsrcID)
{
	src = nsrc;
	srcID = nsrcID;
}

void ViewportLink::setLocalDest(ConcreteViewport* ndest, int ndestID)
{
	dest = ndest;
	destID = ndestID;
}

}